← Index
NYTProf Performance Profile   
For /usr/share/koha/opac/cgi-bin/opac/opac-search.pl
  Run on Tue Oct 15 11:58:52 2013
Reported on Tue Oct 15 12:02:30 2013

Filename(eval 1123)[/usr/lib/perl5/Template/Document.pm:78]
StatementsExecuted 4 statements in 6µs
Eval Invoked At/usr/lib/perl5/Template/Document.pm line 78
Sibling evals1, 2, 3, 4, 5, 6, 7, 8
Line State
ments
Time
on line
Calls Time
in subs
Code
1sub {
211µs my $context = shift || die "template sub called without context\n";
314µs13µs my $stash = $context->stash;
# spent 3µs making 1 call to Template::Context::stash
41600ns my $output = '';
51300ns my $_tt_error;
6
7 eval { BLOCK: {
8#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
9$stash->set('TagsShowEnabled', ($stash->get('TagsEnabled') && $stash->get('TagsShowOnList')));
10$output .= " ";
11#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
12$stash->set('TagsInputEnabled', ($stash->get('opacuserlogin') && $stash->get('TagsEnabled') && $stash->get('TagsInputOnList')));
13$output .= " ";
14#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
15$output .= $context->include('doc-head-open.inc');
16$output .= " ";
17#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
18if (($stash->get('LibraryNameTitle'))) {
19#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
20$output .= $stash->get('LibraryNameTitle');
21}
22else {
23$output .= "Koha online";
24}
25
26$output .= " catalogue › ";
27#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
28if (($stash->get('searchdesc'))) {
29$output .= " Results of search ";
30#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
31if (($stash->get('query_desc'))) {
32$output .= "for '";
33#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
34
35# FILTER
36$output .= do {
37 my $output = '';
38 my $_tt_filter = $context->filter('html')
39 || $context->throw($context->error);
40
41$output .= $stash->get('query_desc');
42
43 &$_tt_filter($output);
44};
45
46$output .= "'";
47}
48
49#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
50if (($stash->get('limit_desc'))) {
51$output .= " with limit(s): '";
52#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
53
54# FILTER
55$output .= do {
56 my $output = '';
57 my $_tt_filter = $context->filter('html')
58 || $context->throw($context->error);
59
60$output .= $stash->get('limit_desc');
61
62 &$_tt_filter($output);
63};
64
65$output .= "'";
66}
67
68$output .= " ";
69}
70else {
71$output .= " You did not specify any search criteria. ";
72}
73
74$output .= " ";
75#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
76$output .= $context->include('doc-head-close.inc');
77$output .= " <link rel=\"alternate\" type=\"application/rss+xml\" title=\"";
78#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
79
80# FILTER
81$output .= do {
82 my $output = '';
83 my $_tt_filter = $context->filter('html')
84 || $context->throw($context->error);
85
86$output .= $stash->get('LibraryName');
87
88 &$_tt_filter($output);
89};
90
91$output .= " Search RSS Feed\" href=\"";
92#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
93$output .= $stash->get('OPACBaseURL');
94$output .= "/cgi-bin/koha/opac-search.pl?";
95#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
96
97# FILTER
98$output .= do {
99 my $output = '';
100 my $_tt_filter = $context->filter('html')
101 || $context->throw($context->error);
102
103$output .= $stash->get('query_cgi');
104
105 &$_tt_filter($output);
106};
107
108#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
109
110# FILTER
111$output .= do {
112 my $output = '';
113 my $_tt_filter = $context->filter('html')
114 || $context->throw($context->error);
115
116$output .= $stash->get('limit_cgi');
117
118 &$_tt_filter($output);
119};
120
121$output .= "&amp;count=";
122#line 1 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
123
124# FILTER
125$output .= do {
126 my $output = '';
127 my $_tt_filter = $context->filter('html')
128 || $context->throw($context->error);
129
130$output .= $stash->get('countrss');
131
132 &$_tt_filter($output);
133};
134
135$output .= "&amp;sort_by=acqdate_dsc&amp;format=rss2\" />\n";
136#line 3 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
137if (($stash->get('OpacStarRatings') eq 'all')) {
138$output .= "<script type=\"text/javascript\" src=\"";
139#line 2 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
140$output .= $stash->get('themelang');
141$output .= "/lib/jquery/plugins/jquery.rating.js\"></script>\n<link rel=\"stylesheet\" type=\"text/css\" href=\"";
142#line 3 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
143$output .= $stash->get('themelang');
144$output .= "/css/jquery.rating.css\" />";
145}
146
147$output .= " <script type=\"text/javascript\" src=\"";
148#line 3 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
149$output .= $stash->get('themelang');
150$output .= "/lib/jquery/plugins/jquery.checkboxes.min.js\"></script>\n";
151#line 5 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
152if (($stash->get('OpacHighlightedWords'))) {
153$output .= "<script type=\"text/javascript\" src=\"";
154#line 4 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
155$output .= $stash->get('themelang');
156$output .= "/lib/jquery/plugins/jquery.highlight-3.js\"></script>\n";
157}
158
159$output .= "<script type=\"text/javascript\">\n//<![CDATA[\n";
160#line 31 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
161if (($stash->get('opacuserlogin'))) {
162#line 31 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
163if (($stash->get('RequestOnOpac'))) {
164$output .= "\nfunction holdMultiple() {\n var checkedBiblioNums = \"\"; // Separated by \"/\"\n var checkedCount = 0;\n if(document.bookbag_form.biblionumber.length > 0) {\n for (var i=0; i < document.bookbag_form.biblionumber.length; i++) {\n if (document.bookbag_form.biblionumber[i].checked) {\n checkedBiblioNums += (document.bookbag_form.biblionumber[i].value + \"/\");\n checkedCount++;\n }\n }\n }\n\n if (checkedCount > 0) {\n holdBiblioNums(checkedBiblioNums);\n } else {\n alert(MSG_NO_RECORD_SELECTED);\n }\n}\n\nfunction holdBiblioNums(numList) {\n // numList: biblio numbers separated by \"/\"\n \$(\"#hold_form_biblios\").attr(\"value\", numList);\n \$(\"#hold_form\").submit();\n}";
165}
166
167}
168
169$output .= "\n\n";
170#line 74 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
171if (($stash->get('TagsInputEnabled') && $stash->get('loggedinusername'))) {
172$output .= "\nfunction tagSelected() {\n var checkedBoxes = \$(\".searchresults :checkbox:checked\");\n if (\$(checkedBoxes).size() == 0) {\n alert(MSG_NO_RECORD_SELECTED);\n } else {\n \$(\"#tagsel_tag\").hide();\n \$(\"#sort_by\").hide();\n \$(\"#tagsel_form\").show();\n }\n}\n\nfunction tagCanceled() {\n \$(\"#tagsel_form\").hide();\n \$(\"#tagsel_tag\").show();\n \$(\"#sort_by\").show();\n \$(\"#tagsel_new\").val(\"\");\n \$(\"#tagsel_status, .tagstatus\").empty().hide();\n}\n\nfunction tagAdded() {\n var checkedBoxes = \$(\".searchresults :checkbox:checked\");\n if (\$(checkedBoxes).size() == 0) {\n alert(MSG_NO_RECORD_SELECTED);\n return false;\n }\n\n var tag = \$(\"#tagsel_new\").val();\n if (!tag || (tag == \"\")) {\n alert(MSG_NO_TAG_SPECIFIED);\n return false;\n }\n\n var bibs = [];\n for (var i = 0; i < \$(checkedBoxes).size(); i++) {\n var box = \$(checkedBoxes).get(i);\n bibs[i] = \$(box).val();\n }\n\n KOHA.Tags.add_multitags_button(bibs, tag);\n return false;\n}";
173}
174
175$output .= "\n";
176#line 93 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
177if (($stash->get('OpacHighlightedWords'))) {
178$output .= "\nvar q_array = new Array(); // holds search terms if available\n\nfunction highlightOff() {\n \$(\"td\").removeHighlight();\n \$(\".highlight_toggle\").toggle();\n}\nfunction highlightOn() {\n var x;\n for (x in q_array) {\n if ( q_array[x].length > 0 ) {\n \$(\".title\").highlight(q_array[x]);\n \$(\".author\").highlight(q_array[x]);\n \$(\".results_summary\").highlight(q_array[x]);\n }\n }\n \$(\".highlight_toggle\").toggle();\n}\n";
179}
180
181$output .= "\n\$(document).ready(function(){\n ";
182#line 99 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
183if (($stash->get('OpacHighlightedWords'))) {
184$output .= "\n \$('a.title').each(function() {\n \$(this).attr(\"href\", \$(this).attr(\"href\") + \"&query_desc=";
185#line 97 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
186
187# FILTER
188$output .= do {
189 my $output = '';
190 my $_tt_filter = $context->filter('uri')
191 || $context->throw($context->error);
192
193$output .= $stash->get('query_desc');
194
195 &$_tt_filter($output);
196};
197
198$output .= "\");\n });\n ";
199}
200
201$output .= "\n\n ";
202#line 132 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
203if (($stash->get('IDreamBooksResults'))) {
204$output .= "\n \$('.idbresult').each(function() {\n var isbn = \$(this).children('a').text().replace(/\\s*/,'');\n var element = this;\n\n if (\$.browser.msie && parseInt(\$.browser.version, 10) >= 8 && window.XDomainRequest) {\n // Use Microsoft XDR for IE version 8 or above\n var xdr = new XDomainRequest();\n xdr.open(\"get\", \"http://idreambooks.com/newbooks/api.json?q=\"+encodeURIComponent(isbn)+\"&key=8bf66516232d1b72f3e47df939653e1e\");\n xdr.onload = function() {\n json = 'json = '+xdr.responseText; // the string now looks like.. json = { ... };\n eval(json); // json is now a regular JSON object\n if(json.total_results > 0 && json.book.rating > 0){\n \$(element).children('a').html(\"<img src='\"+json.book.to_read_or_not_small+\"' alt='\"+json.book.title+\" by \"+json.book.author+\"' title='Rating based on reviews of \"+json.book.title+\"'>\"+json.book.rating+\"%\");\n \$(element).show();\n } else {\n \$(element).remove();\n }\n }\n xdr.send();\n } else {\n \$.getJSON(\"http://idreambooks.com/newbooks/api.json?q=\"+encodeURIComponent(isbn)+\"&key=8bf66516232d1b72f3e47df939653e1e\", function(json){\n if(json.total_results > 0 && json.book.rating > 0){\n \$(element).children('a').html(\"<img src='\"+json.book.to_read_or_not_small+\"' alt='\"+json.book.title+\" by \"+json.book.author+\"' title='Rating based on reviews of \"+json.book.title+\"'>\"+json.book.rating+\"%\");\n \$(element).show();\n } else {\n \$(element).remove();\n }\n });\n }\n });\n ";
205}
206
207$output .= "\n\n ";
208#line 134 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
209if (($stash->get('opacbookbag'))) {
210$output .= "\$(\".addtocart\").show();";
211}
212
213$output .= "\n\n";
214#line 167 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
215if (($stash->get('opacbookbag'))) {
216$output .= "\n ";
217#line 155 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
218if (($stash->get('virtualshelves'))) {
219$output .= "\n var param1 = \"<label for=\\\"addto\\\">\"+_(\"Add to: \")+\"<\\/label><select name=\\\"addto\\\" id=\\\"addto\\\"><option value=\\\"\\\"><\\/option>\";\n ";
220#line 140 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
221if (($stash->get('opacbookbag'))) {
222$output .= " param1 += \"<option value=\\\"addtocart\\\">\"+_(\"Cart\")+\"<\\/option>\";\n ";
223}
224
225#line 151 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
226if (($stash->get('virtualshelves'))) {
227#line 150 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
228if (($stash->get('loggedinusername'))) {
229#line 143 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
230if (($stash->get('addbarshelves'))) {
231$output .= "\n param1 += \"<optgroup label=\\\"\"+_(\"Your lists:\")+\"\\\">\";";
232#line 142 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
233
234# FOREACH
235do {
236 my ($_tt_value, $_tt_error, $_tt_oldloop);
237 my $_tt_list = $stash->get('addbarshelvesloop');
238
239 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
240 $_tt_list = Template::Config->iterator($_tt_list)
241 || die $Template::Config::ERROR, "\n";
242 }
243
244 ($_tt_value, $_tt_error) = $_tt_list->get_first();
245 eval { $_tt_oldloop = $stash->get('loop') };
246 $stash->set('loop', $_tt_list);
247 eval {
248FOR1: while (! $_tt_error) {
249 $stash->{'addbarshelvesloo'} = $_tt_value;
250$output .= "\n param1 += \"<option id=\\\"s";
251#line 142 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
252$output .= $stash->get(['addbarshelvesloo', 0, 'shelfnumber', 0]);
253$output .= "\\\" value=\\\"addtolist\\\">";
254#line 142 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
255
256# FILTER
257$output .= do {
258 my $output = '';
259 my $_tt_filter = $context->filter('html')
260 || $context->throw($context->error);
261
262$output .= $stash->get(['addbarshelvesloo', 0, 'shelfname', 0]);
263
264 &$_tt_filter($output);
265};
266
267$output .= "<\\/option>\";";;
268 ($_tt_value, $_tt_error) = $_tt_list->get_next();
269 }
270 };
271 $stash->set('loop', $_tt_oldloop);
272 die $@ if $@;
273 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
274 die $_tt_error if $_tt_error;
275};
276
277$output .= "\n param1 += \"<\\/optgroup>\";";
278}
279
280$output .= "\n ";
281#line 145 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
282if (($stash->get('addpubshelves'))) {
283$output .= "param1 += \"<optgroup label=\\\"\"+_(\"Public lists:\")+\"\\\">\"";
284#line 144 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
285
286# FOREACH
287do {
288 my ($_tt_value, $_tt_error, $_tt_oldloop);
289 my $_tt_list = $stash->get('addpubshelvesloop');
290
291 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
292 $_tt_list = Template::Config->iterator($_tt_list)
293 || die $Template::Config::ERROR, "\n";
294 }
295
296 ($_tt_value, $_tt_error) = $_tt_list->get_first();
297 eval { $_tt_oldloop = $stash->get('loop') };
298 $stash->set('loop', $_tt_list);
299 eval {
300FOR1: while (! $_tt_error) {
301 $stash->{'addpubshelvesloo'} = $_tt_value;
302$output .= "+\"<option id=\\\"s";
303#line 144 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
304$output .= $stash->get(['addpubshelvesloo', 0, 'shelfnumber', 0]);
305$output .= "\\\" value=\\\"addtolist\\\">";
306#line 144 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
307
308# FILTER
309$output .= do {
310 my $output = '';
311 my $_tt_filter = $context->filter('html')
312 || $context->throw($context->error);
313
314$output .= $stash->get(['addpubshelvesloo', 0, 'shelfname', 0]);
315
316 &$_tt_filter($output);
317};
318
319$output .= "<\\/option>\"";;
320 ($_tt_value, $_tt_error) = $_tt_list->get_next();
321 }
322 };
323 $stash->set('loop', $_tt_oldloop);
324 die $@ if $@;
325 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
326 die $_tt_error if $_tt_error;
327};
328
329$output .= ";\n param1 += \"<\\/optgroup>\";";
330}
331
332$output .= "\n ";
333#line 148 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
334if ((($stash->get('addbarshelvesloop') && $stash->get(['addbarshelvesloop', 0, 'size', 0]) > 9) || ($stash->get('addpubshelvesloop') && $stash->get(['addpubshelvesloop', 0, 'size', 0]) > 9))) {
335$output .= "\n param1 += \"<option value=\\\"morelists\\\">[ \"+_(\"More lists\")+\" ]<\\/option>\";\n ";
336}
337
338$output .= "\n param1 += \"<option value=\\\"newlist\\\">[ \"+_(\"New list\")+\" ]<\\/option>\";\n ";
339}
340
341$output .= "\n ";
342}
343
344$output .= "\n param1 += \"<\\/select> <input type=\\\"submit\\\" class=\\\"submit\\\" value=\\\"\"+_(\"Save\")+\"\\\" />\";\n ";
345}
346else {
347$output .= "\n var param1 = \"<a id=\\\"addto\\\" class=\\\"addtocart\\\" href=\\\"#\\\">\" + _(\"Add to cart\") + \"<\\/a>\";\n ";
348}
349
350$output .= "\n";
351}
352else {
353$output .= "\n var param1 = \"<label for=\\\"addto\\\">\"+_(\"Add to list: \")+\"<\\/label><select name=\\\"addto\\\" id=\\\"addto\\\"><option value=\\\"\\\"><\\/option>\";\n";
354#line 165 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
355if (($stash->get('virtualshelves'))) {
356#line 164 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
357if (($stash->get('loggedinusername'))) {
358#line 161 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
359if (($stash->get('addbarshelves'))) {
360$output .= "\n param1 += \"<optgroup label=\\\"\"+_(\"Your lists:\")+\"\\\">\";";
361#line 160 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
362
363# FOREACH
364do {
365 my ($_tt_value, $_tt_error, $_tt_oldloop);
366 my $_tt_list = $stash->get('addbarshelvesloop');
367
368 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
369 $_tt_list = Template::Config->iterator($_tt_list)
370 || die $Template::Config::ERROR, "\n";
371 }
372
373 ($_tt_value, $_tt_error) = $_tt_list->get_first();
374 eval { $_tt_oldloop = $stash->get('loop') };
375 $stash->set('loop', $_tt_list);
376 eval {
377FOR1: while (! $_tt_error) {
378 $stash->{'addbarshelvesloo'} = $_tt_value;
379$output .= "\n param1 += \"<option id=\\\"s";
380#line 160 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
381$output .= $stash->get(['addbarshelvesloo', 0, 'shelfnumber', 0]);
382$output .= "\\\" value=\\\"addtolist\\\">";
383#line 160 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
384
385# FILTER
386$output .= do {
387 my $output = '';
388 my $_tt_filter = $context->filter('html')
389 || $context->throw($context->error);
390
391$output .= $stash->get(['addbarshelvesloo', 0, 'shelfname', 0]);
392
393 &$_tt_filter($output);
394};
395
396$output .= "<\\/option>\";";;
397 ($_tt_value, $_tt_error) = $_tt_list->get_next();
398 }
399 };
400 $stash->set('loop', $_tt_oldloop);
401 die $@ if $@;
402 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
403 die $_tt_error if $_tt_error;
404};
405
406$output .= "\n param1 += \"<\\/optgroup>\";";
407}
408
409$output .= "\n ";
410#line 162 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
411if (($stash->get('addpubshelves'))) {
412$output .= "param1 += \"<optgroup label=\\\"\"+_(\"Public lists:\")+\"\\\">\"";
413#line 162 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
414
415# FOREACH
416do {
417 my ($_tt_value, $_tt_error, $_tt_oldloop);
418 my $_tt_list = $stash->get('addpubshelvesloop');
419
420 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
421 $_tt_list = Template::Config->iterator($_tt_list)
422 || die $Template::Config::ERROR, "\n";
423 }
424
425 ($_tt_value, $_tt_error) = $_tt_list->get_first();
426 eval { $_tt_oldloop = $stash->get('loop') };
427 $stash->set('loop', $_tt_list);
428 eval {
429FOR1: while (! $_tt_error) {
430 $stash->{'addpubshelvesloo'} = $_tt_value;
431$output .= "+\"<option id=\\\"s";
432#line 162 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
433$output .= $stash->get(['addpubshelvesloo', 0, 'shelfnumber', 0]);
434$output .= "\\\" value=\\\"addtolist\\\">";
435#line 162 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
436
437# FILTER
438$output .= do {
439 my $output = '';
440 my $_tt_filter = $context->filter('html')
441 || $context->throw($context->error);
442
443$output .= $stash->get(['addpubshelvesloo', 0, 'shelfname', 0]);
444
445 &$_tt_filter($output);
446};
447
448$output .= "<\\/option>\"";;
449 ($_tt_value, $_tt_error) = $_tt_list->get_next();
450 }
451 };
452 $stash->set('loop', $_tt_oldloop);
453 die $@ if $@;
454 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
455 die $_tt_error if $_tt_error;
456};
457
458}
459
460$output .= "\n param1 +=\"<\\/optgroup><option value=\\\"newlist\\\">[ \"+_(\"New list\")+\" ]<\\/option>\"\n ";
461}
462
463$output .= "\n ";
464}
465
466$output .= "\n param1 += \"<\\/select> <input type=\\\"submit\\\" class=\\\"submit\\\" value=\\\"\"+_(\"Save\")+\"\\\" />\";\n";
467}
468
469$output .= "\n\n \$('#sortsubmit').hide();\n \$('#sort_by').change(function() {\n \$('#bookbag_form').submit();\n });\n \$(\"span.clearall\").html(\"<a id=\\\"CheckNone\\\" href=\\\"#\\\">\"+_(\"Clear all\")+\"<\\/a>\");\n \$(\"span.checkall\").html(\"<a id=\\\"CheckAll\\\" href=\\\"#\\\">\"+_(\"Select all\")+\"<\\/a>\");\n";
470#line 175 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
471if (($stash->get('opacbookbag'))) {
472$output .= "\$(\"span.addto\").html(param1);";
473}
474else {
475#line 175 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
476if (($stash->get('virtualshelves'))) {
477#line 175 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
478if (($stash->get('loggedinusername'))) {
479$output .= "\$(\"span.addto\").html(param1);";
480}
481
482}
483
484}
485
486$output .= "\n";
487#line 191 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
488if (($stash->get('opacbookbag') || $stash->get('virtualshelves'))) {
489$output .= "\n ";
490#line 190 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
491if (($stash->get('virtualshelves'))) {
492$output .= "\n \$(\"#addto\").change(function(){\n cartList();\n });\n \$(\".addto\").find(\"input:submit\").click(function(){\n cartList();\n return false;\n });\n ";
493}
494else {
495$output .= "\n \$(\"#addto\").click(function(){\n cartList();\n return false;\n });\n ";
496}
497
498$output .= "\n";
499}
500
501$output .= "\n\n function cartList(){\n if(\$(\"#addto\").find(\"option:selected\").attr(\"value\") == \"addtolist\"){\n var shelfnumber = \$(\"#addto\").find(\"option:selected\").attr(\"id\").replace(\"s\",\"\");\n if (vShelfAdd()) {\n Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?selectedshelf='+shelfnumber+'&' + vShelfAdd());\n }\n return false;\n } else if(\$(\"#addto\").find(\"option:selected\").attr(\"value\") == \"newlist\"){\n ";
502#line 203 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
503if (($stash->get('loggedinusername'))) {
504$output .= "if (vShelfAdd()) {\n Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?newshelf=1&' + vShelfAdd());\n }";
505}
506else {
507$output .= " alert(_(\"You must be logged in to create or add to lists\")); ";
508}
509
510$output .= "\n return false;\n } else if(\$(\"#addto\").find(\"option:selected\").attr(\"value\") == \"morelists\"){\n ";
511#line 208 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
512if (($stash->get('loggedinusername'))) {
513$output .= "if (vShelfAdd()) {\n Dopop('/cgi-bin/koha/opac-addbybiblionumber.pl?' + vShelfAdd());\n }";
514}
515else {
516$output .= " alert(_(\"You must be logged in to create or add to lists\")); ";
517}
518
519$output .= "\n return false;\n }\n if(\$(\"#addto\").find(\"option:selected\").attr(\"value\") == \"addtocart\" || \$(\"#addto\").attr(\"class\") == \"addtocart\"){\n addMultiple();\n return false;\n }\n }\n \$(\"#CheckAll\").click(function(){\n \$(\"#bookbag_form\").checkCheckboxes();\n return false;\n });\n \$(\"#CheckNone\").click(function(){\n \$(\"#bookbag_form\").unCheckCheckboxes();\n return false;\n });\n";
520#line 234 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
521if (($stash->get('RequestOnOpac'))) {
522$output .= "\n ";
523#line 233 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
524if (($stash->get('opacuserlogin'))) {
525$output .= "\n ";
526#line 232 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
527if (($stash->get('DisplayMultiPlaceHold'))) {
528$output .= "\n \$(\"#placehold\").html(\"<input class=\\\"submit\\\" type=\\\"submit\\\" value=\\\"\"+_(\"Place reserve\")+\"\\\"/>\");\n \$(\"#placehold\").find(\"input:submit\").click(function(){\n holdMultiple();\n return false;\n });\n ";
529}
530
531$output .= "\n ";
532}
533
534$output .= "\n";
535}
536
537$output .= "\n \$(\"#holdDetails\").hide();\n\n";
538#line 246 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
539if (($stash->get('query_desc'))) {
540#line 246 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
541if (($stash->get('OpacHighlightedWords'))) {
542$output .= "var query_desc = \"";
543#line 237 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
544
545# FILTER
546$output .= do {
547 my $output = '';
548 my $_tt_filter = $context->filter('html')
549 || $context->throw($context->error);
550
551
552# FILTER
553$output .= do {
554 my $output = '';
555 my $_tt_filter = $context->filter('replace', [ '\r', '\\r' ])
556 || $context->throw($context->error);
557
558
559# FILTER
560$output .= do {
561 my $output = '';
562 my $_tt_filter = $context->filter('replace', [ '\n', '\\n' ])
563 || $context->throw($context->error);
564
565
566# FILTER
567$output .= do {
568 my $output = '';
569 my $_tt_filter = $context->filter('replace', [ '\'', ('' . "'") ])
570 || $context->throw($context->error);
571
572$output .= $stash->get('query_desc');
573
574 &$_tt_filter($output);
575};
576
577
578 &$_tt_filter($output);
579};
580
581
582 &$_tt_filter($output);
583};
584
585
586 &$_tt_filter($output);
587};
588
589$output .= "\";\n q_array = query_desc.split(\" \");\n // ensure that we don't have \"\" at the end of the array, which can\n // break the highlighter\n while (q_array.length > 0 && q_array[q_array.length-1] == \"\") {\n q_array = q_array.splice(0,-1);\n }\n highlightOn();\n \$(\"#highlight_toggle_on\" ).hide().click(function() {highlightOn() ;});\n \$(\"#highlight_toggle_off\").show().click(function() {highlightOff();});";
590}
591
592}
593
594$output .= "\n\n";
595#line 290 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
596if (($stash->get('TagsInputEnabled') && $stash->get('loggedinusername'))) {
597$output .= "\n \$(\"#tagsel_tag\").click(function(){\n tagSelected();\n return false;\n });\n \$(\"#tagsel_cancel\").click(function(){\n tagCanceled();\n return false;\n });\n \$(\"#tagsel_button\").click(function(){\n tagAdded();\n return false;\n });\n\n \$(\".tag_add\").click(function(){\n var thisid = \$(this).attr(\"id\");\n thisid = thisid.replace(\"tag_add\",\"\");\n \$(this).hide();\n \$(\"#tagform\"+thisid).show();\n \$(\"#newtag\"+thisid).focus();\n \$(\"#newtag\"+thisid+\"_status\").empty().hide();\n return false;\n });\n \$(\".cancel_tag_add\").click(function(){\n var thisid = \$(this).attr(\"id\");\n thisid = thisid.replace(\"cancel\",\"\");\n \$(\"#tagform\"+thisid).hide();\n \$(\"#tag_add\"+thisid).show();\n \$(\"#newtag\"+thisid).val(\"\");\n \$(\"#newtag\"+thisid+\"_status\").empty().hide();\n return false;\n });\n \$(\".tagbutton\").click(function(){\n var thisid = \$(this).attr(\"title\");\n var tag = \$(\"#newtag\"+thisid).val();\n if (!tag || (tag == \"\")) {\n alert(MSG_NO_TAG_SPECIFIED);\n return false;\n }\n KOHA.Tags.add_tag_button(thisid, tag);\n return false;\n });\n";
598}
599
600$output .= "\n ";
601#line 291 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
602if ($stash->get('OpenLibraryCovers')) {
603$output .= "KOHA.OpenLibrary.GetCoverFromIsbn();";
604}
605
606$output .= "\n ";
607#line 292 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
608if ($stash->get('OPACLocalCoverImages')) {
609$output .= "KOHA.LocalCover.GetCoverFromBibnumber(false);";
610}
611
612$output .= "\n ";
613#line 293 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
614if (($stash->get('GoogleJackets'))) {
615$output .= "KOHA.Google.GetCoverFromIsbn();";
616}
617
618$output .= "\n\n";
619#line 303 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
620if (($stash->get('DidYouMean'))) {
621$output .= "\n \$(\"#didyoumean\").load(\"/cgi-bin/koha/svc/suggestion?render=stub&q=";
622#line 296 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
623
624# FILTER
625$output .= do {
626 my $output = '';
627 my $_tt_filter = $context->filter('uri')
628 || $context->throw($context->error);
629
630$output .= $stash->get('querystring');
631
632 &$_tt_filter($output);
633};
634
635$output .= "\",\n function() {\n \$(\".searchsuggestion\").parent().parent().css({\n \"border-color\": \"#F4ECBE\",\n \"background-color\": \"#FFFBEA\"\n });\n });\n";
636}
637
638$output .= "\n\n});\n\n//]]>\n</script>\n</head>\n<body id=\"results\">\n ";
639#line 311 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
640if (($stash->get('opacfacets'))) {
641$output .= "<div id=\"doc3\" class=\"yui-t1\">";
642}
643else {
644$output .= "<div id=\"doc3\" class=\"yui-t7\">";
645}
646
647$output .= " <div id=\"bd\">\n\n";
648#line 313 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
649$output .= $context->include('masthead.inc');
650$output .= " <div id=\"yui-main\">\n <div class=\"yui-b\">\n <div id=\"userresults\" class=\"container\">\n ";
651#line 317 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
652if (($stash->get('DidYouMean'))) {
653$output .= " <div id=\"didyoumean\">Not what you expected? Check for <a href=\"/cgi-bin/koha/svc/suggestion?render=standalone&amp;q=";
654#line 316 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
655
656# FILTER
657$output .= do {
658 my $output = '';
659 my $_tt_filter = $context->filter('uri')
660 || $context->throw($context->error);
661
662$output .= $stash->get('querystring');
663
664 &$_tt_filter($output);
665};
666
667$output .= "\">suggestions</a></div>\n ";
668}
669
670$output .= " <div id=\"top-pages\">";
671#line 317 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
672$output .= $context->include('page-numbers.inc');
673$output .= "</div>\n ";
674#line 323 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
675if (($stash->get('koha_spsuggest'))) {
676$output .= " Did you mean: <ul style=\"list-style: none;\">\n ";
677#line 322 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
678
679# FOREACH
680do {
681 my ($_tt_value, $_tt_error, $_tt_oldloop);
682 my $_tt_list = $stash->get('SPELL_SUGGEST');
683
684 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
685 $_tt_list = Template::Config->iterator($_tt_list)
686 || die $Template::Config::ERROR, "\n";
687 }
688
689 ($_tt_value, $_tt_error) = $_tt_list->get_first();
690 eval { $_tt_oldloop = $stash->get('loop') };
691 $stash->set('loop', $_tt_list);
692 eval {
693FOR1: while (! $_tt_error) {
694 $stash->{'SPELL_SUGGES'} = $_tt_value;
695$output .= " <li>\n <a href=\"/cgi-bin/koha/opac-search.pl?q=";
696#line 320 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
697$output .= $stash->get(['SPELL_SUGGES', 0, 'spsuggestion', 0]);
698$output .= "\">";
699#line 320 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
700$output .= $stash->get(['SPELL_SUGGES', 0, 'spsuggestion', 0]);
701$output .= "</a>\n </li>\n ";;
702 ($_tt_value, $_tt_error) = $_tt_list->get_next();
703 }
704 };
705 $stash->set('loop', $_tt_oldloop);
706 die $@ if $@;
707 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
708 die $_tt_error if $_tt_error;
709};
710
711$output .= " </ul>\n";
712}
713
714$output .= " ";
715#line 326 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
716if (($stash->get('query_error'))) {
717$output .= " <div class=\"dialog alert\">\n <h4>Error:</h4>\n ";
718#line 325 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
719$output .= $stash->get('query_error');
720$output .= " </div>\n";
721}
722
723$output .= "\n\n<!-- Search Results Table -->\n";
724#line 520 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
725if (($stash->get('total'))) {
726$output .= "\n";
727#line 518 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
728if (($stash->get('scan'))) {
729$output .= "\n <h1>Scan index:</h1>\n <form action=\"/cgi-bin/koha/opac-search.pl\" method=\"get\">\n <table>\n <tr>\n <td>\n Scan index for: <input type=\"text\" name=\"q\" id=\"scan-index\" size=\"35\" value=\"\" />\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"scan-index\">Indexed in:</label>\n <select name=\"idx\" id=\"scan-index\">\n <option value=\"\">Any word</option>\n <option value=\"kw,phr:\">Any phrase</option>\n <option value=\"ti:\">Title</option>\n <option value=\"ti,phr:\">Title phrase</option>\n <option value=\"au,phr:\">Author</option>\n <option value=\"su:\">Subject</option>\n <option value=\"su,phr:\">Subject phrase</option>\n <option value=\"se:\">Series</option>\n <option value=\"pb:\">Publisher</option>\n <option value=\"nt:\">Notes</option>\n <option value=\"se:\">Series Title</option>\n <option value=\"sn:\">ISBN</option>\n <option value=\"ss:\">ISSN</option>\n </select>\n <input type=\"hidden\" name=\"scan\" value=\"1\" />\n </td>\n </tr>\n </table>\n </form>\n\n <form action=\"/cgi-bin/koha/opac-search.pl\" method=\"get\">\n <table>\n <tr>\n <th>Term/Phrase</th>\n <th>Count</th>\n </tr>\n ";
730#line 377 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
731
732# FOREACH
733do {
734 my ($_tt_value, $_tt_error, $_tt_oldloop);
735 my $_tt_list = $stash->get('SEARCH_RESULTS');
736
737 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
738 $_tt_list = Template::Config->iterator($_tt_list)
739 || die $Template::Config::ERROR, "\n";
740 }
741
742 ($_tt_value, $_tt_error) = $_tt_list->get_first();
743 eval { $_tt_oldloop = $stash->get('loop') };
744 $stash->set('loop', $_tt_list);
745 eval {
746FOR1: while (! $_tt_error) {
747 $stash->{'SEARCH_RESULT'} = $_tt_value;
748$output .= " ";
749#line 371 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
750if (($stash->get(['SEARCH_RESULT', 0, 'even', 0]))) {
751$output .= " <tr class=\"highlight\">\n ";
752}
753else {
754$output .= " <tr>\n ";
755}
756
757$output .= " <td>\n <a href=\"/cgi-bin/koha/opac-search.pl?q=";
758#line 372 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
759
760# FILTER
761$output .= do {
762 my $output = '';
763 my $_tt_filter = $context->filter('url')
764 || $context->throw($context->error);
765
766$output .= $stash->get(['SEARCH_RESULT', 0, 'scan_use', 0]);
767
768 &$_tt_filter($output);
769};
770
771$output .= "&quot;";
772#line 372 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
773
774# FILTER
775$output .= do {
776 my $output = '';
777 my $_tt_filter = $context->filter('url')
778 || $context->throw($context->error);
779
780$output .= $stash->get(['SEARCH_RESULT', 0, 'title', 0]);
781
782 &$_tt_filter($output);
783};
784
785$output .= "&quot;\">";
786#line 372 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
787if (($stash->get(['SEARCH_RESULT', 0, 'title', 0]))) {
788#line 372 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
789
790# FILTER
791$output .= do {
792 my $output = '';
793 my $_tt_filter = $context->filter('html')
794 || $context->throw($context->error);
795
796$output .= $stash->get(['SEARCH_RESULT', 0, 'title', 0]);
797
798 &$_tt_filter($output);
799};
800
801}
802else {
803$output .= "No title";
804}
805
806$output .= "</a>\n </td>\n <td>\n ";
807#line 375 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
808$output .= $stash->get(['SEARCH_RESULT', 0, 'author', 0]);
809$output .= " </td>\n </tr>\n ";;
810 ($_tt_value, $_tt_error) = $_tt_list->get_next();
811 }
812 };
813 $stash->set('loop', $_tt_oldloop);
814 die $@ if $@;
815 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
816 die $_tt_error if $_tt_error;
817};
818
819$output .= " </table>\n </form>\n";
820}
821else {
822$output .= " <div class=\"searchresults\">\n <form action=\"/cgi-bin/koha/opac-search.pl\" method=\"get\" name=\"bookbag_form\" id=\"bookbag_form\">\n ";
823#line 384 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
824if (($stash->get('searchdesc'))) {
825$output .= " ";
826#line 382 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
827
828# FOREACH
829do {
830 my ($_tt_value, $_tt_error, $_tt_oldloop);
831 my $_tt_list = $stash->get('QUERY_INPUTS');
832
833 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
834 $_tt_list = Template::Config->iterator($_tt_list)
835 || die $Template::Config::ERROR, "\n";
836 }
837
838 ($_tt_value, $_tt_error) = $_tt_list->get_first();
839 eval { $_tt_oldloop = $stash->get('loop') };
840 $stash->set('loop', $_tt_list);
841 eval {
842FOR1: while (! $_tt_error) {
843 $stash->{'QUERY_INPUT'} = $_tt_value;
844$output .= " <input type=\"hidden\" name=\"";
845#line 381 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
846
847# FILTER
848$output .= do {
849 my $output = '';
850 my $_tt_filter = $context->filter('html')
851 || $context->throw($context->error);
852
853$output .= $stash->get(['QUERY_INPUT', 0, 'input_name', 0]);
854
855 &$_tt_filter($output);
856};
857
858$output .= "\" value=\"";
859#line 381 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
860
861# FILTER
862$output .= do {
863 my $output = '';
864 my $_tt_filter = $context->filter('html')
865 || $context->throw($context->error);
866
867$output .= $stash->get(['QUERY_INPUT', 0, 'input_value', 0]);
868
869 &$_tt_filter($output);
870};
871
872$output .= "\"/>\n ";;
873 ($_tt_value, $_tt_error) = $_tt_list->get_next();
874 }
875 };
876 $stash->set('loop', $_tt_oldloop);
877 die $@ if $@;
878 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
879 die $_tt_error if $_tt_error;
880};
881
882$output .= " ";
883#line 383 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
884
885# FOREACH
886do {
887 my ($_tt_value, $_tt_error, $_tt_oldloop);
888 my $_tt_list = $stash->get('LIMIT_INPUTS');
889
890 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
891 $_tt_list = Template::Config->iterator($_tt_list)
892 || die $Template::Config::ERROR, "\n";
893 }
894
895 ($_tt_value, $_tt_error) = $_tt_list->get_first();
896 eval { $_tt_oldloop = $stash->get('loop') };
897 $stash->set('loop', $_tt_list);
898 eval {
899FOR1: while (! $_tt_error) {
900 $stash->{'LIMIT_INPUT'} = $_tt_value;
901$output .= " <input type=\"hidden\" name=\"";
902#line 382 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
903
904# FILTER
905$output .= do {
906 my $output = '';
907 my $_tt_filter = $context->filter('html')
908 || $context->throw($context->error);
909
910$output .= $stash->get(['LIMIT_INPUT', 0, 'input_name', 0]);
911
912 &$_tt_filter($output);
913};
914
915$output .= "\" value=\"";
916#line 382 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
917
918# FILTER
919$output .= do {
920 my $output = '';
921 my $_tt_filter = $context->filter('html')
922 || $context->throw($context->error);
923
924$output .= $stash->get(['LIMIT_INPUT', 0, 'input_value', 0]);
925
926 &$_tt_filter($output);
927};
928
929$output .= "\"/>\n ";;
930 ($_tt_value, $_tt_error) = $_tt_list->get_next();
931 }
932 };
933 $stash->set('loop', $_tt_oldloop);
934 die $@ if $@;
935 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
936 die $_tt_error if $_tt_error;
937};
938
939$output .= "\n ";
940}
941
942$output .= "\n\n <!-- TABLE RESULTS START -->\n <table>\n <tr><td colspan=\"6\" class=\"resultscontrol\">\n <div class=\"resort\"> <select id=\"sort_by\" name=\"sort_by\"> ";
943#line 389 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
944$output .= $context->include('resort_form.inc');
945$output .= " </select> <input type=\"submit\" class=\"submit clearfix\" id=\"sortsubmit\" value=\"Go\" /></div>\n <div class=\"cartlist\">\n <!-- checkall, clearall are now needed for placehold -->\n <span class=\"checkall\"></span>\n <span class=\"clearall\"></span>\n ";
946#line 396 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
947if (($stash->get('OpacHighlightedWords'))) {
948$output .= " <a href=\"#\" class=\"highlight_toggle\" id=\"highlight_toggle_off\">Unhighlight</a>\n <a href=\"#\" class=\"highlight_toggle\" id=\"highlight_toggle_on\">Highlight</a>\n ";
949}
950
951$output .= " ";
952#line 397 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
953if (($stash->get('opacbookbag') || $stash->get('virtualshelves'))) {
954$output .= " <span class=\"addto\"></span>\n ";
955}
956
957$output .= " <span id=\"placehold\"><!-- input class=\"submit\" type=\"submit\" value=\"Place Hold\"/ --></span>\n <div id=\"holdDetails\"></div>\n\n ";
958#line 411 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
959if (($stash->get('TagsInputEnabled') && $stash->get('loggedinusername'))) {
960$output .= " <span id=\"tagsel_span\">\n <input id=\"tagsel_tag\" class=\"submit\" type=\"submit\" value=\"Tag\"/>\n </span>\n <span id=\"tagsel_form\" style=\"display:none\">\n <label for=\"tagsel_new\">New tag:</label>\n <input name=\"tagsel_new\" id=\"tagsel_new\" maxlength=\"100\" />\n <input id=\"tagsel_button\" name=\"tagsel_button\" class=\"input tagsel_button\" title=\"Add\" type=\"submit\" value=\"Add\" />\n <a href=\"#\" id=\"tagsel_cancel\">(done)</a>\n </span>\n <span id=\"tagsel_status\" class=\"tagsel_tatus\" style=\"display:none;\">\n Tag status here. </span>\n ";
961}
962
963$output .= " </div>\n\n </td></tr>\n <!-- Actual Search Results -->\n ";
964#line 511 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
965
966# FOREACH
967do {
968 my ($_tt_value, $_tt_error, $_tt_oldloop);
969 my $_tt_list = $stash->get('SEARCH_RESULTS');
970
971 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
972 $_tt_list = Template::Config->iterator($_tt_list)
973 || die $Template::Config::ERROR, "\n";
974 }
975
976 ($_tt_value, $_tt_error) = $_tt_list->get_first();
977 eval { $_tt_oldloop = $stash->get('loop') };
978 $stash->set('loop', $_tt_list);
979 eval {
980FOR1: while (! $_tt_error) {
981 $stash->{'SEARCH_RESULT'} = $_tt_value;
982$output .= "\n ";
983#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
984if (!(($stash->get(['loop', 0, 'odd', 0])))) {
985$output .= "\n <tr class=\"highlight\">\n ";
986}
987else {
988$output .= " <tr>\n ";
989}
990
991$output .= " <td class=\"select selectcol\">";
992#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
993if (($stash->get('opacbookbag'))) {
994$output .= "<input type=\"checkbox\" id=\"bib";
995#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
996$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
997$output .= "\" name=\"biblionumber\" value=\"";
998#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
999$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1000$output .= "\" /> <label for=\"bib";
1001#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1002$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1003$output .= "\"></label>";
1004}
1005else {
1006$output .= " ";
1007#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1008if (($stash->get('virtualshelves'))) {
1009$output .= "<input type=\"checkbox\" id=\"bib";
1010#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1011$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1012$output .= "\" name=\"biblionumber\" value=\"";
1013#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1014$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1015$output .= "\" /> <label for=\"bib";
1016#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1017$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1018$output .= "\"></label>";
1019}
1020else {
1021$output .= " ";
1022#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1023if (($stash->get('RequestOnOpac'))) {
1024#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1025if (!(($stash->get(['SEARCH_RESULT', 0, 'norequests', 0])))) {
1026#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1027if (($stash->get('opacuserlogin'))) {
1028$output .= "<input type=\"checkbox\" id=\"bib";
1029#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1030$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1031$output .= "\" name=\"biblionumber\" value=\"";
1032#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1033$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1034$output .= "\" /> <label for=\"bib";
1035#line 419 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1036$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1037$output .= "\"></label>";
1038}
1039
1040}
1041
1042}
1043
1044}
1045
1046}
1047
1048$output .= "</td>\n <td class=\"select selectcol\">";
1049#line 420 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1050if (!($stash->get('suppress_result_number'))) {
1051#line 420 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1052$output .= $stash->get(['SEARCH_RESULT', 0, 'result_number', 0]);
1053$output .= ".";
1054}
1055
1056$output .= "</td>\n\n ";
1057#line 426 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1058if (! $stash->get('item_level_itypes') || $stash->get('BiblioItemtypeImage') eq 'Koha') {
1059$output .= " ";
1060#line 426 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1061if (!(($stash->get('noItemTypeImages')))) {
1062$output .= " <td class=\"itypecol\">\n ";
1063#line 424 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1064if (($stash->get(['SEARCH_RESULT', 0, 'imageurl', 0]))) {
1065$output .= " <img src=\"";
1066#line 423 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1067$output .= $stash->get(['SEARCH_RESULT', 0, 'imageurl', 0]);
1068$output .= "\" title=\"";
1069#line 423 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1070$output .= $stash->get(['SEARCH_RESULT', 0, 'description', 0]);
1071$output .= "\" alt=\"";
1072#line 423 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1073$output .= $stash->get(['SEARCH_RESULT', 0, 'description', 0]);
1074$output .= "\" />\n ";
1075}
1076
1077$output .= " ";
1078#line 425 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1079if (($stash->get(['SEARCH_RESULT', 0, 'score_avg', 0]))) {
1080$output .= " <img src=\"";
1081#line 424 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1082$output .= $stash->get('themelang');
1083$output .= "/../images/bonus.png\" title=\"bonus\" style=\"max-height: 35px;\"/>\n ";
1084}
1085
1086$output .= " </td>\n ";
1087}
1088
1089$output .= " ";
1090}
1091
1092$output .= " ";
1093#line 429 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1094if (($stash->get('AuthorisedValueImages'))) {
1095$output .= " <td class=\"itypecol\">\n ";
1096#line 428 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1097
1098# FOREACH
1099do {
1100 my ($_tt_value, $_tt_error, $_tt_oldloop);
1101 my $_tt_list = $stash->get(['SEARCH_RESULT', 0, 'authorised_value_images', 0]);
1102
1103 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1104 $_tt_list = Template::Config->iterator($_tt_list)
1105 || die $Template::Config::ERROR, "\n";
1106 }
1107
1108 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1109 eval { $_tt_oldloop = $stash->get('loop') };
1110 $stash->set('loop', $_tt_list);
1111 eval {
1112FOR2: while (! $_tt_error) {
1113 $stash->{'authorised_value_image'} = $_tt_value;
1114$output .= " ";
1115#line 428 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1116if (($stash->get(['authorised_value_image', 0, 'imageurl', 0]))) {
1117$output .= " <img src=\"";
1118#line 427 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1119$output .= $stash->get(['authorised_value_image', 0, 'imageurl', 0]);
1120$output .= "\" alt=\"";
1121#line 427 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1122$output .= $stash->get(['authorised_value_image', 0, 'label', 0]);
1123$output .= "\" title=\"";
1124#line 427 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1125$output .= $stash->get(['authorised_value_image', 0, 'label', 0]);
1126$output .= "\">\n ";
1127}
1128
1129$output .= " ";;
1130 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1131 }
1132 };
1133 $stash->set('loop', $_tt_oldloop);
1134 die $@ if $@;
1135 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1136 die $_tt_error if $_tt_error;
1137};
1138
1139$output .= " </td>\n ";
1140}
1141
1142$output .= " <td>\n ";
1143#line 433 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1144if (($stash->get('COinSinOPACResults'))) {
1145$output .= "\n ";
1146#line 433 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1147if (($stash->get(['SEARCH_RESULT', 0, 'coins', 0]))) {
1148$output .= "\n <!-- COinS / Openurl --><span class=\"Z3988\" title=\"";
1149#line 432 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1150$output .= $stash->get(['SEARCH_RESULT', 0, 'coins', 0]);
1151$output .= "\"></span>\n ";
1152}
1153
1154$output .= " ";
1155}
1156
1157$output .= " ";
1158#line 451 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1159if (($stash->get('OPACXSLTResultsDisplay'))) {
1160$output .= " ";
1161#line 433 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1162$output .= $stash->get(['SEARCH_RESULT', 0, 'XSLTResultsRecord', 0]);
1163$output .= " ";
1164}
1165else {
1166$output .= " ";
1167#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1168if (($stash->get('BiblioDefaultViewmarc'))) {
1169$output .= "<a class=\"title\" href=\"/cgi-bin/koha/opac-MARCdetail.pl?biblionumber=";
1170#line 433 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1171
1172# FILTER
1173$output .= do {
1174 my $output = '';
1175 my $_tt_filter = $context->filter('url')
1176 || $context->throw($context->error);
1177
1178$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1179
1180 &$_tt_filter($output);
1181};
1182
1183$output .= "\" title=\"View details for this title\">\n ";
1184}
1185else {
1186$output .= " ";
1187#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1188if (($stash->get('BiblioDefaultViewisbd'))) {
1189$output .= "<a class=\"title\" href=\"/cgi-bin/koha/opac-ISBDdetail.pl?biblionumber=";
1190#line 434 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1191
1192# FILTER
1193$output .= do {
1194 my $output = '';
1195 my $_tt_filter = $context->filter('url')
1196 || $context->throw($context->error);
1197
1198$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1199
1200 &$_tt_filter($output);
1201};
1202
1203$output .= "\" title=\"View details for this title\">\n ";
1204}
1205else {
1206$output .= "<a class=\"title\" href=\"/cgi-bin/koha/opac-detail.pl?biblionumber=";
1207#line 435 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1208
1209# FILTER
1210$output .= do {
1211 my $output = '';
1212 my $_tt_filter = $context->filter('url')
1213 || $context->throw($context->error);
1214
1215$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1216
1217 &$_tt_filter($output);
1218};
1219
1220$output .= "\" title=\"View details for this title\">\n ";
1221}
1222
1223$output .= " ";
1224}
1225
1226$output .= " ";
1227#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1228if (($stash->get(['SEARCH_RESULT', 0, 'title', 0]))) {
1229#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1230
1231# FILTER
1232$output .= do {
1233 my $output = '';
1234 my $_tt_filter = $context->filter('html')
1235 || $context->throw($context->error);
1236
1237$output .= $stash->get(['SEARCH_RESULT', 0, 'title', 0]);
1238
1239 &$_tt_filter($output);
1240};
1241
1242}
1243else {
1244$output .= "No title";
1245}
1246
1247$output .= " ";
1248#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1249
1250# FOREACH
1251do {
1252 my ($_tt_value, $_tt_error, $_tt_oldloop);
1253 my $_tt_list = $stash->get(['SEARCH_RESULT', 0, 'subtitle', 0]);
1254
1255 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1256 $_tt_list = Template::Config->iterator($_tt_list)
1257 || die $Template::Config::ERROR, "\n";
1258 }
1259
1260 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1261 eval { $_tt_oldloop = $stash->get('loop') };
1262 $stash->set('loop', $_tt_list);
1263 eval {
1264FOR2: while (! $_tt_error) {
1265 $stash->{'subtitl'} = $_tt_value;
1266$output .= ", ";
1267#line 436 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1268
1269# FILTER
1270$output .= do {
1271 my $output = '';
1272 my $_tt_filter = $context->filter('html')
1273 || $context->throw($context->error);
1274
1275$output .= $stash->get(['subtitl', 0, 'subfield', 0]);
1276
1277 &$_tt_filter($output);
1278};
1279;
1280 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1281 }
1282 };
1283 $stash->set('loop', $_tt_oldloop);
1284 die $@ if $@;
1285 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1286 die $_tt_error if $_tt_error;
1287};
1288
1289$output .= "</a>\n ";
1290#line 438 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1291if (($stash->get(['SEARCH_RESULT', 0, 'author', 0]))) {
1292$output .= "by <a href=\"/cgi-bin/koha/opac-search.pl?q=au:";
1293#line 437 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1294
1295# FILTER
1296$output .= do {
1297 my $output = '';
1298 my $_tt_filter = $context->filter('url')
1299 || $context->throw($context->error);
1300
1301$output .= $stash->get(['SEARCH_RESULT', 0, 'author', 0]);
1302
1303 &$_tt_filter($output);
1304};
1305
1306$output .= "\" title=\"Search for works by this author\" class=\"author\">";
1307#line 437 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1308$output .= $stash->get(['SEARCH_RESULT', 0, 'author', 0]);
1309$output .= "</a>\n ";
1310}
1311else {
1312$output .= "&nbsp; ";
1313}
1314
1315$output .= " <span class=\"results_summary publisher\"><span class=\"label\">Publication:</span>\n ";
1316#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1317if (($stash->get(['SEARCH_RESULT', 0, 'place', 0]))) {
1318#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1319$output .= $stash->get(['SEARCH_RESULT', 0, 'place', 0]);
1320$output .= " ";
1321}
1322
1323#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1324if (($stash->get(['SEARCH_RESULT', 0, 'publishercode', 0]))) {
1325#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1326
1327# FILTER
1328$output .= do {
1329 my $output = '';
1330 my $_tt_filter = $context->filter('html')
1331 || $context->throw($context->error);
1332
1333$output .= $stash->get(['SEARCH_RESULT', 0, 'publishercode', 0]);
1334
1335 &$_tt_filter($output);
1336};
1337
1338}
1339
1340#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1341if (($stash->get(['SEARCH_RESULT', 0, 'publicationyear', 0]))) {
1342$output .= " ";
1343#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1344$output .= $stash->get(['SEARCH_RESULT', 0, 'publicationyear', 0]);
1345$output .= " ";
1346}
1347else {
1348#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1349if (($stash->get(['SEARCH_RESULT', 0, 'copyrightdate', 0]))) {
1350$output .= " ";
1351#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1352$output .= $stash->get(['SEARCH_RESULT', 0, 'copyrightdate', 0]);
1353}
1354
1355}
1356
1357$output .= " ";
1358#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1359if (($stash->get(['SEARCH_RESULT', 0, 'pages', 0]))) {
1360$output .= ". ";
1361#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1362$output .= $stash->get(['SEARCH_RESULT', 0, 'pages', 0]);
1363}
1364
1365$output .= " ";
1366#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1367if (($stash->get(['SEARCH_RESULT', 0, 'notes', 0]))) {
1368$output .= ", ";
1369#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1370
1371# FILTER
1372$output .= do {
1373 my $output = '';
1374 my $_tt_filter = $context->filter('html')
1375 || $context->throw($context->error);
1376
1377$output .= $stash->get(['SEARCH_RESULT', 0, 'notes', 0]);
1378
1379 &$_tt_filter($output);
1380};
1381
1382}
1383
1384$output .= " ";
1385#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1386if (($stash->get(['SEARCH_RESULT', 0, 'size', 0]))) {
1387$output .= " ";
1388#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1389$output .= $stash->get(['SEARCH_RESULT', 0, 'size', 0]);
1390}
1391
1392$output .= " ";
1393#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1394if (($stash->get(['SEARCH_RESULT', 0, 'timestamp', 0]))) {
1395$output .= " <i>(modified on ";
1396#line 439 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1397$output .= $stash->get(['SEARCH_RESULT', 0, 'timestamp', 0]);
1398$output .= ")</i>";
1399}
1400
1401$output .= " </span>\n ";
1402#line 442 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1403if (($stash->get(['SEARCH_RESULT', 0, 'summary', 0]))) {
1404$output .= " <span class=\"result_summary\">\n ";
1405#line 441 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1406$output .= $stash->get(['SEARCH_RESULT', 0, 'summary', 0]);
1407$output .= " </span>\n ";
1408}
1409
1410$output .= " ";
1411#line 442 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1412if (($stash->get(['SEARCH_RESULT', 0, 'copyrightdate', 0]))) {
1413$output .= "<span class=\"results_summary date\"><span class=\"label\">Date:</span>";
1414#line 442 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1415$output .= $stash->get(['SEARCH_RESULT', 0, 'copyrightdate', 0]);
1416$output .= "</span>";
1417}
1418
1419$output .= " <span class=\"results_summary availability\">\n <span class=\"label\">Availability:</span>\n ";
1420#line 448 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1421if (($stash->get(['SEARCH_RESULT', 0, 'available_items_loop', 0, 'size', 0]))) {
1422$output .= " <span class=\"available\"><strong>Copies available:</strong>\n ";
1423#line 446 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1424
1425# FOREACH
1426do {
1427 my ($_tt_value, $_tt_error, $_tt_oldloop);
1428 my $_tt_list = $stash->get(['SEARCH_RESULT', 0, 'available_items_loop', 0]);
1429
1430 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1431 $_tt_list = Template::Config->iterator($_tt_list)
1432 || die $Template::Config::ERROR, "\n";
1433 }
1434
1435 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1436 eval { $_tt_oldloop = $stash->get('loop') };
1437 $stash->set('loop', $_tt_list);
1438 eval {
1439FOR2: while (! $_tt_error) {
1440 $stash->{'available_items_loo'} = $_tt_value;
1441$output .= " ";
1442#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1443if ($stash->get(['available_items_loo', 0, 'this_branch', 0])) {
1444$output .= "<span class=\"highlight-row-results\">";
1445}
1446else {
1447$output .= "<span>";
1448}
1449
1450$output .= " ";
1451#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1452if (($stash->get('singleBranchMode'))) {
1453$output .= " ";
1454#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1455$output .= $stash->get(['available_items_loo', 0, 'location', 0]);
1456$output .= " ";
1457}
1458else {
1459$output .= " ";
1460#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1461$output .= $stash->get(['available_items_loo', 0, 'branchname', 0]);
1462$output .= " ";
1463}
1464
1465$output .= " ";
1466#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1467if (($stash->get('OPACItemsResultsDisplay'))) {
1468$output .= " ";
1469#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1470if (!(($stash->get('singleBranchMode')))) {
1471#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1472$output .= $stash->get(['available_items_loo', 0, 'location', 0]);
1473}
1474
1475$output .= " ";
1476#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1477if (($stash->get(['available_items_loo', 0, 'itemcallnumber', 0]))) {
1478$output .= "[<a href=\"/cgi-bin/koha/opac-search.pl?q=callnum:";
1479#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1480
1481# FILTER
1482$output .= do {
1483 my $output = '';
1484 my $_tt_filter = $context->filter('url')
1485 || $context->throw($context->error);
1486
1487$output .= $stash->get(['available_items_loo', 0, 'itemcallnumber', 0]);
1488
1489 &$_tt_filter($output);
1490};
1491
1492$output .= "\">";
1493#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1494$output .= $stash->get(['available_items_loo', 0, 'itemcallnumber', 0]);
1495$output .= "</a>]";
1496}
1497
1498$output .= " ";
1499}
1500
1501$output .= " (";
1502#line 445 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1503$output .= $stash->get(['available_items_loo', 0, 'count', 0]);
1504$output .= "), </span>\n ";;
1505 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1506 }
1507 };
1508 $stash->set('loop', $_tt_oldloop);
1509 die $@ if $@;
1510 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1511 die $_tt_error if $_tt_error;
1512};
1513
1514$output .= " </span>\n ";
1515}
1516else {
1517$output .= " ";
1518#line 448 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1519if (($stash->get(['SEARCH_RESULT', 0, 'ALTERNATEHOLDINGS', 0]))) {
1520$output .= " ";
1521#line 447 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1522
1523# FOREACH
1524do {
1525 my ($_tt_value, $_tt_error, $_tt_oldloop);
1526 my $_tt_list = $stash->get(['SEARCH_RESULT', 0, 'ALTERNATEHOLDINGS', 0]);
1527
1528 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1529 $_tt_list = Template::Config->iterator($_tt_list)
1530 || die $Template::Config::ERROR, "\n";
1531 }
1532
1533 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1534 eval { $_tt_oldloop = $stash->get('loop') };
1535 $stash->set('loop', $_tt_list);
1536 eval {
1537FOR2: while (! $_tt_error) {
1538 $stash->{'ALTERNATEHOLDING'} = $_tt_value;
1539$output .= " &nbsp;<span id=\"alternateholdings\">";
1540#line 447 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1541$output .= $stash->get(['ALTERNATEHOLDING', 0, 'holding', 0]);
1542$output .= "</span>, ";;
1543 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1544 }
1545 };
1546 $stash->set('loop', $_tt_oldloop);
1547 die $@ if $@;
1548 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1549 die $_tt_error if $_tt_error;
1550};
1551
1552$output .= " ";
1553}
1554else {
1555$output .= " <span class=\"unavailable\">No items available:</span>\n ";
1556}
1557
1558$output .= " ";
1559}
1560
1561$output .= " <span class=\"unavailable\">\n ";
1562#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1563if (($stash->get(['SEARCH_RESULT', 0, 'onloancount', 0]))) {
1564$output .= " Issued (";
1565#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1566$output .= $stash->get(['SEARCH_RESULT', 0, 'onloancount', 0]);
1567$output .= "), ";
1568}
1569
1570$output .= " ";
1571#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1572if (($stash->get(['SEARCH_RESULT', 0, 'wthdrawncount', 0]))) {
1573$output .= " Withdrawn (";
1574#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1575$output .= $stash->get(['SEARCH_RESULT', 0, 'wthdrawncount', 0]);
1576$output .= "), ";
1577}
1578
1579$output .= " ";
1580#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1581if (!(($stash->get(['SEARCH_RESULT', 0, 'hidelostitems', 0])))) {
1582#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1583if (($stash->get(['SEARCH_RESULT', 0, 'itemlostcount', 0]))) {
1584$output .= " Lost (";
1585#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1586$output .= $stash->get(['SEARCH_RESULT', 0, 'itemlostcount', 0]);
1587$output .= "),";
1588}
1589
1590}
1591
1592$output .= " ";
1593#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1594if (($stash->get(['SEARCH_RESULT', 0, 'damagedcount', 0]))) {
1595$output .= " Damaged (";
1596#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1597$output .= $stash->get(['SEARCH_RESULT', 0, 'damagedcount', 0]);
1598$output .= "),";
1599}
1600
1601$output .= " ";
1602#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1603if (($stash->get(['SEARCH_RESULT', 0, 'orderedcount', 0]))) {
1604$output .= " On order (";
1605#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1606$output .= $stash->get(['SEARCH_RESULT', 0, 'orderedcount', 0]);
1607$output .= "),";
1608}
1609
1610$output .= " ";
1611#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1612if (($stash->get(['SEARCH_RESULT', 0, 'onholdcount', 0]))) {
1613$output .= " On reserve (";
1614#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1615$output .= $stash->get(['SEARCH_RESULT', 0, 'onholdcount', 0]);
1616$output .= "),";
1617}
1618
1619$output .= " ";
1620#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1621if (($stash->get(['SEARCH_RESULT', 0, 'intransitcount', 0]))) {
1622$output .= " In transit (";
1623#line 449 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1624$output .= $stash->get(['SEARCH_RESULT', 0, 'intransitcount', 0]);
1625$output .= "),";
1626}
1627
1628$output .= " </span>\n </span>\n ";
1629}
1630
1631$output .= " ";
1632#line 458 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1633if (($stash->get(['SEARCH_RESULT', 0, 'score_avg', 0]))) {
1634$output .= " <span class=\"result_summary\">\n <img src=\"";
1635#line 452 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1636$output .= $stash->get('themelang');
1637$output .= "/../images/Star";
1638#line 452 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1639$output .= $stash->get(['SEARCH_RESULT', 0, 'score_int', 0]);
1640$output .= ".gif\" title=\"\" style=\"max-height: 15px;\"/> <span style=\"font-size: 85%;\">";
1641#line 452 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1642$output .= $stash->get(['SEARCH_RESULT', 0, 'score_avg', 0]);
1643$output .= " / 5 (on ";
1644#line 452 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1645$output .= $stash->get(['SEARCH_RESULT', 0, 'num_scores', 0]);
1646$output .= " rates)</span>\n ";
1647#line 454 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1648if (($stash->get(['SEARCH_RESULT', 0, 'num_critics', 0]))) {
1649$output .= " <span class=\"social_data\">";
1650#line 453 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1651$output .= $stash->get(['SEARCH_RESULT', 0, 'num_critics', 0]);
1652$output .= " Internet user critics</span>\n ";
1653}
1654
1655$output .= " ";
1656#line 455 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1657if (($stash->get(['SEARCH_RESULT', 0, 'num_critics_pro', 0]))) {
1658$output .= " <span class=\"social_data\">";
1659#line 454 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1660$output .= $stash->get(['SEARCH_RESULT', 0, 'num_critics_pro', 0]);
1661$output .= " Professional critics</span>\n ";
1662}
1663
1664$output .= " ";
1665#line 456 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1666if (($stash->get(['SEARCH_RESULT', 0, 'num_videos', 0]))) {
1667$output .= " <span class=\"social_data\">";
1668#line 455 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1669$output .= $stash->get(['SEARCH_RESULT', 0, 'num_videos', 0]);
1670$output .= " Video extracts</span>\n ";
1671}
1672
1673$output .= " ";
1674#line 457 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1675if (($stash->get(['SEARCH_RESULT', 0, 'num_quotations', 0]))) {
1676$output .= " <span class=\"social_data\">";
1677#line 456 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1678$output .= $stash->get(['SEARCH_RESULT', 0, 'num_quotations', 0]);
1679$output .= " Quotations</span>\n ";
1680}
1681
1682$output .= " </span>\n ";
1683}
1684
1685$output .= " ";
1686#line 458 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1687if (($stash->get('LibraryThingForLibrariesID'))) {
1688$output .= "<div class=\"ltfl_reviews\"></div>";
1689}
1690
1691$output .= " ";
1692#line 462 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1693if (($stash->get('TagsShowEnabled'))) {
1694$output .= " ";
1695#line 462 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1696if (($stash->get(['SEARCH_RESULT', 0, 'TagLoop', 0, 'size', 0]))) {
1697$output .= " <div class=\"results_summary tags\"><span class=\"label\">Tags:</span>\n <ul style=\"display: inline; list-style: none;\">";
1698#line 460 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1699
1700# FOREACH
1701do {
1702 my ($_tt_value, $_tt_error, $_tt_oldloop);
1703 my $_tt_list = $stash->get(['SEARCH_RESULT', 0, 'TagLoop', 0]);
1704
1705 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1706 $_tt_list = Template::Config->iterator($_tt_list)
1707 || die $Template::Config::ERROR, "\n";
1708 }
1709
1710 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1711 eval { $_tt_oldloop = $stash->get('loop') };
1712 $stash->set('loop', $_tt_list);
1713 eval {
1714FOR2: while (! $_tt_error) {
1715 $stash->{'TagLoo'} = $_tt_value;
1716$output .= "<li style=\"display: inline; list-style: none;\"><a href=\"/cgi-bin/koha/opac-search.pl?tag=";
1717#line 459 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1718
1719# FILTER
1720$output .= do {
1721 my $output = '';
1722 my $_tt_filter = $context->filter('url')
1723 || $context->throw($context->error);
1724
1725$output .= $stash->get(['TagLoo', 0, 'term', 0]);
1726
1727 &$_tt_filter($output);
1728};
1729
1730$output .= "&amp;q=";
1731#line 459 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1732
1733# FILTER
1734$output .= do {
1735 my $output = '';
1736 my $_tt_filter = $context->filter('url')
1737 || $context->throw($context->error);
1738
1739$output .= $stash->get(['TagLoo', 0, 'term', 0]);
1740
1741 &$_tt_filter($output);
1742};
1743
1744$output .= "\">";
1745#line 459 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1746$output .= $stash->get(['TagLoo', 0, 'term', 0]);
1747$output .= "</a> <span class=\"weight\">(";
1748#line 459 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1749$output .= $stash->get(['TagLoo', 0, 'weight_total', 0]);
1750$output .= ")</span></li>\n ";;
1751 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1752 }
1753 };
1754 $stash->set('loop', $_tt_oldloop);
1755 die $@ if $@;
1756 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1757 die $_tt_error if $_tt_error;
1758};
1759
1760$output .= " </ul>\n </div>\n ";
1761}
1762
1763$output .= " ";
1764}
1765
1766$output .= " ";
1767#line 462 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1768if (($stash->get(['SEARCH_RESULT', 0, 'searchhighlightblob', 0]))) {
1769$output .= "<span class=\"results_summary\"><span class=\"label\">Match:</span> ";
1770#line 462 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1771$output .= $stash->get(['SEARCH_RESULT', 0, 'searchhighlightblob', 0]);
1772$output .= "</span>";
1773}
1774
1775$output .= " ";
1776#line 472 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1777if (($stash->get('OpacStarRatings') eq 'all')) {
1778$output .= " <div class=\"results_summary ratings\">\n\n";
1779#line 466 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1780
1781# FOREACH
1782do {
1783 my ($_tt_value, $_tt_error, $_tt_oldloop);
1784 my $_tt_list = [ 1, 2, 3, 4, 5 ];
1785
1786 unless (UNIVERSAL::isa($_tt_list, 'Template::Iterator')) {
1787 $_tt_list = Template::Config->iterator($_tt_list)
1788 || die $Template::Config::ERROR, "\n";
1789 }
1790
1791 ($_tt_value, $_tt_error) = $_tt_list->get_first();
1792 eval { $_tt_oldloop = $stash->get('loop') };
1793 $stash->set('loop', $_tt_list);
1794 eval {
1795FOR2: while (! $_tt_error) {
1796 $stash->{'i'} = $_tt_value;
1797$output .= " ";
1798#line 466 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1799if (($stash->get(['SEARCH_RESULT', 0, 'rating_avg', 0]) eq $stash->get('i'))) {
1800$output .= " <input class=\"star\" type=\"radio\" name=\"rating-";
1801#line 464 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1802$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1803$output .= "\" value=\"";
1804#line 464 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1805$output .= $stash->get('i');
1806$output .= "\" checked=\"checked\" disabled=\"disabled\" />\n";
1807}
1808else {
1809$output .= " <input class=\"star\" type=\"radio\" name=\"rating-";
1810#line 465 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1811$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1812$output .= "\" value=\"";
1813#line 465 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1814$output .= $stash->get('i');
1815$output .= "\" disabled=\"disabled\" />\n";
1816}
1817
1818$output .= " ";;
1819 ($_tt_value, $_tt_error) = $_tt_list->get_next();
1820 }
1821 };
1822 $stash->set('loop', $_tt_oldloop);
1823 die $@ if $@;
1824 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
1825 die $_tt_error if $_tt_error;
1826};
1827
1828$output .= " <input type=\"hidden\" name=\"biblionumber\" value=\"";
1829#line 466 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1830$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1831$output .= "\" />\n <input type=\"hidden\" name=\"loggedinuser\" value=\"";
1832#line 467 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1833$output .= $stash->get('loggedinuser');
1834$output .= "\" />\n\n ";
1835#line 471 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1836if (($stash->get(['SEARCH_RESULT', 0, 'rating_total', 0])) > 0) {
1837$output .= " <span id=\"rating_total_";
1838#line 469 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1839$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1840$output .= "\">&nbsp;&nbsp;(";
1841#line 469 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1842$output .= $stash->get(['SEARCH_RESULT', 0, 'rating_total', 0]);
1843$output .= " votes)</span>\n ";
1844}
1845else {
1846$output .= " <br />\n ";
1847}
1848
1849$output .= " </div>\n ";
1850}
1851
1852$output .= " <span class=\"results_summary actions\"><span class=\"label\">Actions:</span>\n ";
1853#line 481 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1854if (($stash->get('RequestOnOpac'))) {
1855$output .= " ";
1856#line 480 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1857if (!(($stash->get(['SEARCH_RESULT', 0, 'norequests', 0])))) {
1858$output .= " ";
1859#line 479 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1860if (($stash->get('opacuserlogin'))) {
1861$output .= " ";
1862#line 478 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1863if (($stash->get('AllowOnShelfHolds'))) {
1864$output .= " <a class=\"hold\" href=\"/cgi-bin/koha/opac-reserve.pl?biblionumber=";
1865#line 473 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1866$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1867$output .= "\">Place reserve</a><!-- add back when available 0 holds in queue-->\n ";
1868}
1869else {
1870$output .= "\n ";
1871#line 477 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1872if (($stash->get(['SEARCH_RESULT', 0, 'itemsissued', 0]))) {
1873$output .= "\n <a class=\"hold\" href=\"/cgi-bin/koha/opac-reserve.pl?biblionumber=";
1874#line 476 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1875$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1876$output .= "\">Place reserve</a><!-- add back when available 0 holds in queue-->\n ";
1877}
1878
1879$output .= "\n ";
1880}
1881
1882$output .= "\n ";
1883}
1884
1885$output .= "\n ";
1886}
1887
1888$output .= "\n ";
1889}
1890
1891$output .= "\n\n ";
1892#line 495 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1893if (($stash->get('TagsInputEnabled'))) {
1894$output .= "\n ";
1895#line 495 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1896if (($stash->get('loggedinusername'))) {
1897$output .= "\n <a class=\"tag_add\" id=\"tag_add";
1898#line 485 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1899$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1900$output .= "\" href=\"#\">Add tag</a>\n <span id=\"tagform";
1901#line 486 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1902$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1903$output .= "\" class=\"tag_results_input\" style=\"display:none;\">\n <label for=\"newtag";
1904#line 487 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1905$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1906$output .= "\">New tag(s), separated by a comma:</label>\n <input name=\"newtag";
1907#line 488 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1908$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1909$output .= "\" id=\"newtag";
1910#line 488 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1911$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1912$output .= "\" maxlength=\"100\" />\n <input name=\"tagbutton\" class=\"tagbutton\" title=\"";
1913#line 489 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1914$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1915$output .= "\" type=\"submit\" value=\"Add\" />\n <a class=\"cancel_tag_add\" id=\"cancel";
1916#line 490 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1917$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1918$output .= "\" href=\"#\">(done)</a>\n </span>\n <span id=\"newtag";
1919#line 492 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1920$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1921$output .= "_status\" class=\"tagstatus\" style=\"display:none;\">\n Tag status here. </span>\n ";
1922}
1923elsif (($stash->get(['loop', 0, 'first', 0]))) {
1924$output .= "<span id=\"login4tags\">Log in to add tags.</span>\n ";
1925}
1926
1927$output .= " ";
1928}
1929
1930$output .= " ";
1931#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1932if (($stash->get('opacuserlogin'))) {
1933#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1934if (($stash->get('loggedinusername'))) {
1935#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1936if (($stash->get('virtualshelves'))) {
1937$output .= "<a class=\"addtoshelf\" href=\"/cgi-bin/koha/opac-addbybiblionumber.pl?biblionumber=";
1938#line 495 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1939$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1940$output .= "\" onclick=\"Dopop('opac-addbybiblionumber.pl?biblionumber=";
1941#line 495 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1942$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1943$output .= "'); return false;\">Save to Lists</a>\n ";
1944}
1945
1946}
1947
1948}
1949
1950$output .= " ";
1951#line 498 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1952if (($stash->get('opacbookbag'))) {
1953$output .= " ";
1954#line 498 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1955if (($stash->get(['SEARCH_RESULT', 0, 'incart', 0]))) {
1956$output .= " <a class=\"addtocart cart";
1957#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1958$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1959$output .= "\" href=\"#\" onclick=\"addRecord('";
1960#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1961$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1962$output .= "'); return false;\">In your cart</a> <a class=\"cartRemove cartR";
1963#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1964$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1965$output .= "\" href=\"#\" onclick=\"delSingleRecord('";
1966#line 496 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1967$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1968$output .= "'); return false;\">(remove)</a>\n ";
1969}
1970else {
1971$output .= " <a class=\"addtocart cart";
1972#line 497 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1973$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1974$output .= "\" href=\"#\" onclick=\"addRecord('";
1975#line 497 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1976$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1977$output .= "'); return false;\">Add to cart</a> <a style=\"display:none;\" class=\"cartRemove cartR";
1978#line 497 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1979$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1980$output .= "\" href=\"#\" onclick=\"delSingleRecord('";
1981#line 497 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1982$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1983$output .= "'); return false;\">(remove)</a>\n ";
1984}
1985
1986$output .= " ";
1987}
1988
1989$output .= " </span>\n </td><td>\n <a class=\"p1\" href=\"/cgi-bin/koha/opac-detail.pl?biblionumber=";
1990#line 500 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1991$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
1992$output .= "\">\n ";
1993#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1994if (($stash->get('OPACLocalCoverImages'))) {
1995$output .= "<span title=\"";
1996#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
1997
1998# FILTER
1999$output .= do {
2000 my $output = '';
2001 my $_tt_filter = $context->filter('url')
2002 || $context->throw($context->error);
2003
2004$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2005
2006 &$_tt_filter($output);
2007};
2008
2009$output .= "\" class=\"";
2010#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2011$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2012$output .= "\" id=\"local-thumbnail";
2013#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2014$output .= $stash->get(['loop', 0, 'count', 0]);
2015$output .= "\"></span>";
2016}
2017
2018$output .= " ";
2019#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2020if (($stash->get('OPACAmazonCoverImages'))) {
2021#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2022if (($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]))) {
2023#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2024if (($stash->get('using_https'))) {
2025$output .= "<span title=\"";
2026#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2027$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2028$output .= "\" id=\"amazon-thumbnail";
2029#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2030$output .= $stash->get(['loop', 0, 'count', 0]);
2031$output .= "\"><img src=\"https://images-na.ssl-images-amazon.com/images/P/";
2032#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2033$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2034$output .= ".01.TZZZZZZZ.jpg\" alt=\"\" class=\"thumbnail\" /></span>";
2035}
2036else {
2037$output .= "<span title=\"";
2038#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2039$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2040$output .= "\" id=\"amazon-thumbnail";
2041#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2042$output .= $stash->get(['loop', 0, 'count', 0]);
2043$output .= "\"><img src=\"http://images.amazon.com/images/P/";
2044#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2045$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2046$output .= ".01.TZZZZZZZ.jpg\" alt=\"\" class=\"thumbnail\" /></span>";
2047}
2048
2049}
2050else {
2051$output .= "<span class=\"no-image\">No cover image available</span>";
2052}
2053
2054}
2055
2056$output .= " ";
2057#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2058if (($stash->get('SyndeticsEnabled'))) {
2059$output .= " ";
2060#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2061if (($stash->get('SyndeticsCoverImages'))) {
2062$output .= " ";
2063#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2064if ($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0])) {
2065$output .= " ";
2066#line 503 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2067if (($stash->get('using_https'))) {
2068$output .= " <span title=\"";
2069#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2070$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2071$output .= "\" id=\"syndetics-thumbnail";
2072#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2073$output .= $stash->get(['loop', 0, 'count', 0]);
2074$output .= "\"><img src=\"https://secure.syndetics.com/index.aspx?isbn=";
2075#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2076$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2077$output .= "/SC.GIF&amp;client=";
2078#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2079$output .= $stash->get('SyndeticsClientCode');
2080$output .= "&amp;type=xw10&amp;upc=";
2081#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2082$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_upc', 0]);
2083$output .= "&amp;oclc=";
2084#line 501 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2085$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_oclc', 0]);
2086$output .= "\" alt=\"\" class=\"thumbnail\" /></span>\n ";
2087}
2088else {
2089$output .= " <span title=\"";
2090#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2091$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2092$output .= "\" id=\"syndetics-thumbnail";
2093#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2094$output .= $stash->get(['loop', 0, 'count', 0]);
2095$output .= "\"><img src=\"http://www.syndetics.com/index.aspx?isbn=";
2096#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2097$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2098$output .= "/SC.GIF&amp;client=";
2099#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2100$output .= $stash->get('SyndeticsClientCode');
2101$output .= "&amp;type=xw10&amp;upc=";
2102#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2103$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_upc', 0]);
2104$output .= "&amp;oclc=";
2105#line 502 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2106$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_oclc', 0]);
2107$output .= "\" alt=\"\" class=\"thumbnail\" /></span>\n ";
2108}
2109
2110$output .= " ";
2111}
2112else {
2113$output .= " <span class=\"no-image\">No cover image available</span>\n ";
2114}
2115
2116$output .= " ";
2117}
2118
2119$output .= " ";
2120}
2121
2122$output .= " ";
2123#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2124if (($stash->get('GoogleJackets'))) {
2125#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2126if (($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]))) {
2127$output .= "<span style=\"block\" title=\"";
2128#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2129
2130# FILTER
2131$output .= do {
2132 my $output = '';
2133 my $_tt_filter = $context->filter('url')
2134 || $context->throw($context->error);
2135
2136$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2137
2138 &$_tt_filter($output);
2139};
2140
2141$output .= "\" class=\"";
2142#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2143$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2144$output .= "\" id=\"gbs-thumbnail";
2145#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2146$output .= $stash->get(['loop', 0, 'count', 0]);
2147$output .= "\"></span>";
2148}
2149else {
2150$output .= "<span class=\"no-image\">No cover image available</span>";
2151}
2152
2153}
2154
2155$output .= " ";
2156#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2157if ($stash->get('OpenLibraryCovers')) {
2158#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2159if ($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0])) {
2160$output .= "<span style=\"block\" title=\"";
2161#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2162$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2163$output .= "\" class=\"";
2164#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2165$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2166$output .= "\" id=\"openlibrary-thumbnail";
2167#line 504 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2168$output .= $stash->get(['loop', 0, 'count', 0]);
2169$output .= "\"></span>";
2170}
2171else {
2172$output .= "<span class=\"no-image\">No cover image available</span>";
2173}
2174
2175}
2176
2177$output .= " </a>\n ";
2178#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2179if (($stash->get('BakerTaylorEnabled'))) {
2180#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2181if (($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]))) {
2182$output .= "<a href=\"https://";
2183#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2184
2185# FILTER
2186$output .= do {
2187 my $output = '';
2188 my $_tt_filter = $context->filter('html')
2189 || $context->throw($context->error);
2190
2191$output .= $stash->get('BakerTaylorBookstoreURL');
2192
2193 &$_tt_filter($output);
2194};
2195
2196#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2197$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2198$output .= "\"><img alt=\"See Baker &amp; Taylor\" src=\"";
2199#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2200
2201# FILTER
2202$output .= do {
2203 my $output = '';
2204 my $_tt_filter = $context->filter('html')
2205 || $context->throw($context->error);
2206
2207$output .= $stash->get('BakerTaylorImageURL');
2208
2209 &$_tt_filter($output);
2210};
2211
2212#line 505 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2213$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2214$output .= "\" /></a>";
2215}
2216else {
2217$output .= "<span class=\"no-image\">No cover image available</span>";
2218}
2219
2220}
2221
2222$output .= " ";
2223#line 509 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2224if (($stash->get('IDreamBooksResults'))) {
2225#line 509 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2226if (($stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]))) {
2227$output .= "<div class=\"idbresult\" style=\"display: none;\">\n ";
2228#line 508 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2229if (($stash->get('IDreamBooksReviews'))) {
2230$output .= " <a href=\"/cgi-bin/koha/opac-detail.pl?biblionumber=";
2231#line 506 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2232$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2233$output .= "#idb_critic_reviews\">\n ";
2234}
2235else {
2236$output .= " <a href=\"/cgi-bin/koha/opac-detail.pl?biblionumber=";
2237#line 507 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2238$output .= $stash->get(['SEARCH_RESULT', 0, 'biblionumber', 0]);
2239$output .= "\">\n ";
2240}
2241
2242$output .= " ";
2243#line 508 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2244$output .= $stash->get(['SEARCH_RESULT', 0, 'normalized_isbn', 0]);
2245$output .= "</a></div>\n ";
2246}
2247
2248}
2249
2250$output .= " </td>\n </tr>\n ";;
2251 ($_tt_value, $_tt_error) = $_tt_list->get_next();
2252 }
2253 };
2254 $stash->set('loop', $_tt_oldloop);
2255 die $@ if $@;
2256 $_tt_error = 0 if $_tt_error && $_tt_error eq Template::Constants::STATUS_DONE;
2257 die $_tt_error if $_tt_error;
2258};
2259
2260$output .= " </table>\n </form>\n <form id=\"hold_form\" name=\"hold_form\" method=\"get\" action=\"/cgi-bin/koha/opac-reserve.pl\">\n <!-- The value will be set by holdBiblioNums() in basket.js -->\n <input id=\"hold_form_biblios\" type=\"hidden\" name=\"biblionumbers\" value=\"\"/>\n </form>\n </div>\n ";
2261}
2262
2263$output .= " <div id=\"bottom-pages\">";
2264#line 518 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2265$output .= $context->include('page-numbers.inc');
2266$output .= "</div>\n\n ";
2267}
2268else {
2269$output .= " ";
2270}
2271
2272$output .= " ";
2273#line 520 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2274if (($stash->get('suggestion'))) {
2275$output .= " ";
2276#line 520 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2277if (($stash->get('AnonSuggestions'))) {
2278$output .= "<div class=\"suggestion\">Not finding what you're looking for?<br /> Make a <a href=\"/cgi-bin/koha/opac-suggestions.pl?op=add\">purchase suggestion</a></div>";
2279}
2280else {
2281#line 520 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2282if (($stash->get('loggedinusername'))) {
2283$output .= "<div class=\"suggestion\">Not finding what you're looking for?<br /> Make a <a href=\"/cgi-bin/koha/opac-suggestions.pl?op=add\">purchase suggestion</a></div>";
2284}
2285
2286}
2287
2288$output .= " ";
2289}
2290
2291$output .= " </div>\n</div>\n</div>\n ";
2292#line 528 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2293if (($stash->get('opacfacets'))) {
2294$output .= " <div class=\"yui-b\"><div id=\"facetcontainer\" class=\"container\">\n <!-- FACETS START -->\n ";
2295#line 525 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2296$output .= $context->include('opac-facets.inc');
2297$output .= "\n <!-- FACETS END -->\n</div></div>\n ";
2298}
2299
2300$output .= " </div>\n\n";
2301#line 532 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2302if (($stash->get('LibraryThingForLibrariesID'))) {
2303$output .= " ";
2304#line 532 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2305if (($stash->get('using_https'))) {
2306$output .= " <script src=\"https://ltfl.librarything.com/forlibraries/widget.js?id=";
2307#line 530 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2308$output .= $stash->get('LibraryThingForLibrariesID');
2309$output .= "&amp;systype=koha\" type=\"text/javascript\"></script>\n";
2310}
2311else {
2312$output .= " <script src=\"http://ltfl.librarything.com/forlibraries/widget.js?id=";
2313#line 531 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2314$output .= $stash->get('LibraryThingForLibrariesID');
2315$output .= "&amp;systype=koha\" type=\"text/javascript\"></script>\n";
2316}
2317
2318$output .= " ";
2319}
2320
2321$output .= " ";
2322#line 532 "/usr/share/koha/opac/htdocs/opac-tmpl/prog/en-NZ/modules/opac-results.tt"
2323$output .= $context->include('opac-bottom.inc');
2324$output .= " ";
2325 } };
2326 if ($@) {
2327 $_tt_error = $context->catch($@, \$output);
2328 die $_tt_error unless $_tt_error->type eq 'return';
2329 }
2330
2331 return $output;
2332}
2333
2334;